package com.ysu.yybk.mapper.checkin;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ysu.yybk.entity.checkin.Checkin;
import com.ysu.yybk.entity.course.Course;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

/**
 * @author ：lhw
 * @date ：Created in 2019/11/18 21:39
 */
@Repository
public interface CheckinMapper extends BaseMapper<Checkin> {
    @Select("select * from checkin where course_id = #{courseId} and end_time is null for update")
    List<Checkin> getListForUpdate(String courseId);
}
